'use strict';

var gulp = require('gulp');
var sass = require('gulp-sass');
var connect = require('gulp-connect');

gulp.task('sass', function () {
  return gulp.src('src/*.scss')
    .pipe(sass.sync().on('error', sass.logError))
    .pipe(gulp.dest('dist/css'));
});

gulp.task('connect', function() {
  connect.server({
		root: './',
		livereload: true
	});
});

gulp.task('watch', function() {
	gulp.watch(['src/*.scss'], ['sass']);
});

gulp.task('default', ['watch', 'sass', 'connect']);
